import qdarktheme
from PyQt5.QtWidgets import *
from ui.main_window import Ui_MainWindow
import sys
from views.net_assist_widget1 import NetAssistWidget1



class MainWindow(QMainWindow):

    def __init__(self):
        super().__init__()
        # 创建对象
        self.ui = Ui_MainWindow()
        # 初始化内容
        self.ui.setupUi(self)
        # 初始化ui
        self.init_ui()


    def init_ui(self):
        self.ui.tabWidget.addTab(NetAssistWidget1(self), "STM32")
        self.ui.tabWidget.setCurrentIndex(1)
        pass


def main():
    app = QApplication(sys.argv)
    qdarktheme.setup_theme("dark")
    window = MainWindow()

    window.show()
    sys.exit(app.exec_())


if __name__ == '__main__':
    main()